<template>
  <div>
    <el-form ref="form" :model="form" label-width="80px">
      <el-form-item label="标题">
        <el-input :v-model="form.name" />
      </el-form-item>
      <el-form-item label="封面">
        <el-upload
          class="upload-demo"
          action="https://jsonplaceholder.typicode.com/posts/"
          multiple
          :limit="3"
          :v-model="form.cover"
        >
          <el-button size="small" type="primary">点击上传</el-button>
          <div slot="tip" class="el-upload__tip">
            只能上传jpg/png文件,且不超过500kb
          </div>
        </el-upload>
      </el-form-item>
      <el-form-item label="作者">
        <el-input :v-model="form.author" />
      </el-form-item>
      <el-form-item label="视频地址">
        <el-input :v-model="form.video" />
      </el-form-item>
      <el-form-item label="投币数">
        <el-input :v-model="form.perated" />
      </el-form-item>
      <el-form-item label="点赞数">
        <el-input :v-model="form.giveThe" />
      </el-form-item>
      <el-form-item label="发布日期">
        <el-input :v-model="form.data" />
      </el-form-item>
      <el-form-item>
        <el-button type="primary">添加</el-button>
        <el-button>取消</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
export default {
  name: 'Attr',
  data() {
    return {
      form: {
        name: '',
        cover: '',
        author: '',
        video: '',
        perated: '',
        giveThe: '',
        data: ''
      }
    }
  }
}
</script>

<style lang="scss" scoped>
div {
  width: 600px;
}
</style>
